﻿Imports Actuariat

Public Class DlgSelMedic
    Dim _controleurSelectionMedicale As controleurSelectionMedicale
    Dim _moteur As Moteur_Echeancier
    Public Sub New(ByVal controleurSelectionMedicale As controleurSelectionMedicale, _
                   ByVal moteurEcheancier As Moteur_Echeancier)
        InitializeComponent()
        _moteur = moteurEcheancier
        _controleurSelectionMedicale = controleurSelectionMedicale
        NumUpDown_NbDeroult.Value = _controleurSelectionMedicale.getNbMaxDeroulement
        dgv_ValeursDistinctes.DataSource = _controleurSelectionMedicale.getValeursDataTable
    End Sub
    Private Sub NumUpDown_NbDeroult_ValueChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles NumUpDown_NbDeroult.ValueChanged
        _controleurSelectionMedicale.setNbMaxDeroulement(NumUpDown_NbDeroult.Value)
        dgv_ValeursDistinctes.DataSource = _controleurSelectionMedicale.getValeursDataTable
        NumUpDown_NbDeroult.Value = _controleurSelectionMedicale.getNbMaxDeroulement
    End Sub
    Private Sub btnValider_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnValider.Click
        _moteur.calculScenarioCentral()
        Me.Close()
    End Sub
End Class